#ifndef __DLG_LETTER_LIST_H__
#define __DLG_LETTER_LIST_H__

#include <map>
class dlg_addrbook_card_view;
class dlg_letter_list : public CDialogBase
{
	DECLARE_DYNAMIC(dlg_letter_list)

public:
	dlg_letter_list(CWnd* pParent = NULL);
	virtual ~dlg_letter_list();
	enum { IDD = IDD_DLG_LETTER_LIST };
protected:
	virtual void DoDataExchange(CDataExchange* pDX);
	DECLARE_MESSAGE_MAP()

public:
	virtual BOOL OnInitDialog();
	afx_msg void OnSize(UINT nType, int cx, int cy);
	void dskin_window();
	std::string toupper_str(std::string strVal);
	void get_leter_by_code(int code, std::string& leter);
	std::string get_first_leter(std::string text);
	void on_click_btn_letter( UINT msg_id );
	void set_dlg_card_view(dlg_addrbook_card_view* dlg){ this->dlg_card_view_ = dlg;}
	void set_letter_pos();
	TCHAR get_btn_first_letter(UINT btn_id);

	void set_letter_count_and_pos();

private:
	contact_info_lis_type contact_info_list_;
	dlg_addrbook_card_view* dlg_card_view_;
	typedef std::map<int, TCHAR> show_btn_map_type;
	show_btn_map_type btn_map_;
	
	BOOL is_wnd_create_;
};

#endif